import org.junit.Assert;
import org.junit.Test;

import static org.junit.Assert.*;

public class CaculatorTest {
    @Test
    public void shouldReturn2When1Plus1() throws ClassNotFoundException, InstantiationException, IllegalAccessException {
        Caculator caculator = new Caculator();
        int actualResult = caculator.compute(1,1,"Add");
        int expectResult = 2;
        Assert.assertEquals(actualResult, expectResult);
    }
    @Test
    public void shouldReturn0When1Sub1() throws ClassNotFoundException, InstantiationException, IllegalAccessException {
        Caculator caculator = new Caculator();
        int actualResult = caculator.compute(1,1,"Sub");
        int expectResult = 0;
        Assert.assertEquals(actualResult, expectResult);
    }

}